<layout name='Layout/layout_main' />
<script type="text/javascript">
	$(document).ready(function() {
		set_return_url();
		$(function(){
			$(".input-date").datepicker();
			$("#slider-range-important").slider({
				range : "min",
				min : 1,
				max : 5,
				value : 3,
				slide : function(event, ui){
					$("#important").val(ui.value);
					$("div.slider_box div.ui-widget-header").css("background-color", schedule_bg(ui.value, $("#urgency").val()));
				}
			});

			$("#important").val($("#slider-range-important").slider("value"));
			$("#slider-range-urgency").slider({
				range : "min",
				min : 1,
				max : 5,
				value : 3,
				slide : function(event, ui) {
					$("#urgency").val(ui.value);
					$("div.slider_box div.ui-widget-header").css("background-color", schedule_bg($("#important").val(), ui.value));
				}
			});
			$("#urgency").val($("#slider-range-urgency").slider("value"));
			$("div.slider_box div.ui-widget-header").css("background-color", schedule_bg(3, 3));
		})
	});
	function month_view() {
		window.open("__URL__", "_self");
	}
</script>
<div class="schedule">
	<form id="form_search" method='post' >
		<div class="row-fluid title">
			<span>日程搜索</span>
			<div class="input-append right">
				<input type="text"  onkeydown="key_search();" name="keyword" id="keyword">
				<a class="btn" type="button" onclick="btn_search();"> <i class="icon-search"></i>
				</a>
				<a class="btn" onclick="open_search();"> <i class="icon-angle-down"></i>
				</a>
			</div>
		</div>
		<div class="row-fluid adv_search">
			<div class="row-fluid adv_search_head">
				<h4 class="left">高级搜索</h4>
				<div class="right text-right">
					<a  class="btn" onclick="adv_search();">搜索</a>
					<a  class="btn" onclick="close_search();">关闭</a>
				</div>
			</div>
			<div class="row-fluid form-horizontal">
				<div class="control-group span6">
					<label class="control-label" for="li_name">主题 ：</label>
					<div class="controls">
						<input type="text" id="li_name" name="li_name"></div>
				</div>
				<div class="control-group span6">
					<label class="control-label" for="li_location">地点：</label>
					<div class="controls">
						<input type="text" id="li_location" name="li_location" ></div>
				</div>
			</div>
			<div class="row-fluid form-horizontal">
				<div class="control-group span6">
					<label class="control-label" for="li_content">内容：</label>
					<div class="controls">
						<input type="text" id="li_content" name="li_content"></div>
				</div>
				<div class="control-group span6">
					<label class="control-label" for="start_date">日期：</label>
					<div class="controls">
						<input  type="text" name="start_date" id="start_date" class="input-date" value="{$start_date}"  readonly="readonly">
						&nbsp;~&nbsp;
						<input type="text" name="end_date" id="end_date" value="{$end_date}" readonly="readonly" class="input-date" ></div>
				</div>
			</div>
		</div>
	</form>
	<form method="post" action="" id="form_data">
		<div class="table">
			<ul>
				<li class="thead">
					<span class="col-9 right">结束时间</span>
					<span class="col-9 right">开始时间</span>
					<span class="col-12 right">地点</span>
					<div class="auto autocut">标题</div>
				</li>
				<if condition="count($list) eq 0 ">
					<li class="tbody text-center">
						<h3>没找到相应的数据</h3>
					</li>
				</ul>
			</div>
		</form>
		<else/>
		<foreach name="list" item="vo">
			<li class="tbody">
				<span class="col-9 right text-center">{$vo.end_date}</span>
				<span class="col-9 right text-center">{$vo.start_date}</span>
				<span class="col-12 right text-center">{$vo.location}&nbsp;</span>
				<div class="auto autocut">
					<a href="{:U('read2?id='.$vo['id'])}">
						{$vo.name}
						<eq name="vo.name|strlen" value="0">无标题</eq>
					</a>
				</div>
			</li>
		</foreach>
	</ul>
</div>
</form>
<div class="page">{$page}</div>
</if>
</div>